global lasso  agrishare_1940  manushare_1940 income_tax_payers38   


reghdfe income_rank bartik_standardized if no_edu_head==1 , a(fem byear laani50) cl(muni_g)
estadd local sample "No education"
estadd local mfe "None"
sum income_rank if no_edu_head==1 
estadd scalar ymean=r(mean)
estimates store p1

reghdfe income_rank bartik_standardized  $lasso if no_edu_head==1, a(fem byear laani50) cl(muni_g)
estadd local sample "No education"
estadd local mfe "E-net"
sum income_rank if no_edu_head==1
estadd scalar ymean=r(mean)
estimates store p2

reghdfe income_rank  bartik_standardized  i.manu_quartile i.agri_quartile if no_edu_head==1, a(fem byear laani50) cl(muni_g)
estadd local sample "No education"
estadd local mfe "Groups"
sum income_rank if no_edu_head==1
estadd scalar ymean=r(mean)
estimates store p3

reghdfe income_rank bartikq2 bartikq3 bartikq4 $municontrols if no_edu_head==1, a(fem byear laani50) cl(muni_g)
estadd local sample "No education"
estadd local mfe "Baseline"
sum income_rank if no_edu_head==1
estadd scalar ymean=r(mean)
estimates store p4

reghdfe income_rank bartik_standardized  $municontrols if no_edu_head==1|kansa_edu_head==1, a(fem byear laani50) cl(muni_g)
estadd local sample "Primary or less"
estadd local mfe "Baseline"
sum income_rank if no_edu_head==1|kansa_edu_head==1
estadd scalar ymean=r(mean)
estimates store p5

label var bartik_high "Exposure high"
label var bartikq2 "Exposure q2"
label var bartikq3 "Exposure q3"
label var bartikq4 "Exposure q4"

esttab p1 p2 p3 p4 p5  ///
using "$temp\tables\UM_robust1.tex", ///
mgroups("Income Rank", pattern(1 0 0 0 0) prefix(\multicolumn{@span}{c}{) suffix(}) ///
span erepeat(\cmidrule(lr){@span}) ) ///
replace keep(bartik_standardized bartikq2 bartikq3 bartikq4) nonotes ///
b(%9.3f) se(%9.3f)  stats(N sample  ymean mfe   , fmt(0 3) layout(@ @ @) ///
labels("N" "Sample"  "Y mean" "Municipal controls")) label star(* .1 ** .05 *** .01) nodepvars nomtitle

est clear


reghdfe yos bartik_standardized if no_edu_head==1 , a(fem byear laani50) cl(muni_g)
estadd local sample "No education"
estadd local mfe "None"
sum yos if no_edu_head==1
estadd scalar ymean=r(mean)
estimates store p1

reghdfe yos bartik_standardized  $lasso if no_edu_head==1, a(fem byear laani50) cl(muni_g)
estadd local sample "No education"
estadd local mfe "E-net"
sum yos if no_edu_head==1
estadd scalar ymean=r(mean)
estimates store p2

reghdfe yos  bartik_standardized  i.manu_quartile i.agri_quartile if no_edu_head==1, a(fem byear laani50) cl(muni_g)
estadd local sample "No education"
estadd local mfe "Groups"
sum yos if no_edu_head==1
estadd scalar ymean=r(mean)
estimates store p3

reghdfe yos bartikq2 bartikq3 bartikq4 $municontrols if no_edu_head==1, a(fem byear laani50) cl(muni_g)
estadd local sample "No education"
estadd local mfe "Baseline"
sum yos if no_edu_head==1
estadd scalar ymean=r(mean)
estimates store p4

reghdfe yos bartik_standardized  $municontrols if no_edu_head==1|kansa_edu_head==1, a(fem byear laani50) cl(muni_g)
estadd local sample "Primary or less"
estadd local mfe "Baseline"
sum yos if no_edu_head==1|kansa_edu_head==1
estadd scalar ymean=r(mean)
estimates store p5

label var bartik_high "Exposure high"
label var bartikq2 "Exposure q2"
label var bartikq3 "Exposure q3"
label var bartikq4 "Exposure q4"


esttab p1 p2 p3 p4 p5  ///
using "$temp\tables\UM_robust2.tex", ///
mgroups("Years of Schooling", pattern(1 0 0 0 0) prefix(\multicolumn{@span}{c}{) suffix(}) ///
span erepeat(\cmidrule(lr){@span}) ) ///
replace keep(bartik_standardized bartikq2 bartikq3 bartikq4) nonotes ///
b(%9.3f) se(%9.3f)  stats(N sample  ymean mfe   , fmt(0 3) layout(@ @ @) ///
labels("N" "Sample"  "Y mean" "Municipal controls")) label star(* .1 ** .05 *** .01) nodepvars nomtitle



est clear


reghdfe wc_ex bartik_standardized if no_edu_head==1 , a(fem byear laani50) cl(muni_g)
estadd local sample "No education"
estadd local mfe "None"
sum wc_ex if no_edu_head==1
estadd scalar ymean=r(mean)
estimates store p1

reghdfe wc_ex bartik_standardized  $lasso if no_edu_head==1, a(fem byear laani50) cl(muni_g)
estadd local sample "No education"
estadd local mfe "E-net"
sum wc_ex if no_edu_head==1
estadd scalar ymean=r(mean)
estimates store p2

reghdfe wc_ex  bartik_standardized  i.manu_quartile i.agri_quartile if no_edu_head==1, a(fem byear laani50) cl(muni_g)
estadd local sample "No education"
estadd local mfe "Groups"
sum wc_ex if no_edu_head==1
estadd scalar ymean=r(mean)
estimates store p3

reghdfe wc_ex bartikq2 bartikq3 bartikq4 $municontrols if no_edu_head==1, a(fem byear laani50) cl(muni_g)
estadd local sample "No education"
estadd local mfe "Baseline"
sum wc_ex if no_edu_head==1
estadd scalar ymean=r(mean)
estimates store p4

reghdfe wc_ex bartik_standardized  $municontrols if no_edu_head==1|kansa_edu_head==1, a(fem byear laani50) cl(muni_g)
estadd local sample "Primary or less"
estadd local mfe "Baseline"
sum wc_ex if no_edu_head==1|kansa_edu_head==1
estadd scalar ymean=r(mean)
estimates store p5

label var bartik_high "Exposure high"
label var bartikq2 "Exposure q2"
label var bartikq3 "Exposure q3"
label var bartikq4 "Exposure q4"


esttab p1 p2 p3 p4 p5  ///
using "$temp\tables\UM_robust3.tex", ///
mgroups("White Collar or Executive", pattern(1 0 0 0 0) prefix(\multicolumn{@span}{c}{) suffix(}) ///
span erepeat(\cmidrule(lr){@span}) ) ///
replace keep(bartik_standardized bartikq2 bartikq3 bartikq4) nonotes ///
b(%9.3f) se(%9.3f)  stats(N sample  ymean mfe   , fmt(0 3) layout(@ @ @) ///
labels("N" "Sample"  "Y mean" "Municipal controls")) label star(* .1 ** .05 *** .01) nodepvars nomtitle
